package com.dyp.filterinterceptorlistener.web.listener;

import org.springframework.stereotype.Component;

import javax.servlet.annotation.WebListener;
import javax.servlet.http.HttpSessionEvent;
import javax.servlet.http.HttpSessionListener;

@Component
public class MySessionListener implements HttpSessionListener {
    public void sessionCreated(HttpSessionEvent se) {
        System.out.println("MySessionListener @WebListener session 创建");
    }

    public void sessionDestroyed(HttpSessionEvent se) {
        System.out.println("MySessionListener @WebListener session 销毁");
    }
}
